package com.itheima.springboot_06_demo.mapper;

import com.itheima.springboot_06_demo.pojo.Member;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface MemberMapper {

    @Select("select * from tb_member")
    List<Member> list();

    @Insert("insert into tb_member (name,gender,age,dept_id) values (#{name},#{gender},#{age},#{deptId})")
    void add(Member member);
}
